$OpenBSD: patch-src_ruby_supportlib_phusion_passenger_rb,v 1.1 2016/11/04 22:08:19 jeremy Exp $

Use the specified version of nginx.

Don't store or look for stuff in $HOME, use the passenger directory.

--- src/ruby_supportlib/phusion_passenger.rb.orig	Mon Jul 25 19:56:07 2016
+++ src/ruby_supportlib/phusion_passenger.rb	Tue Nov  1 13:25:08 2016
@@ -33,7 +33,7 @@ module PhusionPassenger
   # Run 'rake src/cxx_supportlib/Constants.h' after changing this number.
   VERSION_STRING = '5.0.30'
 
-  PREFERRED_NGINX_VERSION = '1.10.1'
+  PREFERRED_NGINX_VERSION = '${NGINX_VERSION}'
   NGINX_SHA256_CHECKSUM = '1fd35846566485e03c0e318989561c135c598323ff349c503a6c14826487a801'
 
   PREFERRED_PCRE_VERSION  = '8.39'
@@ -315,13 +315,6 @@ private
   # example `sudo` preserves it. That's why we don't respect it by
   # default.
   def self.home_dir(respect_home_env = false)
-    if respect_home_env
-      home = ENV['HOME'].to_s
-    end
-    if home.nil? || home.empty?
-      require 'etc' if !defined?(Etc)
-      home = Etc.getpwuid(Process.uid).dir
-    end
-    return home
+    File.dirname(File.dirname(File.expand_path(__FILE__)))
   end
 end if !defined?(PhusionPassenger::VERSION_STRING)
